﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Configuration;
using System.Runtime.InteropServices;
using System.Drawing;

namespace Liang.Model
{
    public class Const
    {
        /// <summary>
        /// 命名空间
        /// </summary>
        public static readonly string NAMESPACE = ConfigurationManager.AppSettings["namespace"];

        /// <summary>
        /// 项目名称
        /// </summary>
        public static readonly string PROJECT_NAME = ConfigurationManager.AppSettings["projectName"];

        /// <summary>
        /// 空密码
        /// </summary>
        public const string PASSWORD_NULL = "Liang_null_password";

        /// <summary>
        /// 系统时间
        /// </summary>
        public const string SYS_TIME = "/auth/getDateTime";

        /// <summary>
        /// login rest
        /// </summary>
        public const string LOGIN_SRC = "/auth";

        /// <summary>
        /// XML登录验证 login/{loginName}/{pwd}/
        /// </summary>
        public const string LOGIN = "/login";

        /// <summary>
        /// JSON 登录验证 loginJson
        /// </summary>
        public const string LOGINJSON = "/loginJson";


        /// <summary>
        /// 用户注册  registerJson/{organName}/{name}/{phone}/{user}
        /// </summary>
        public const string REGISTER = "/register/registerJson";

        /// <summary>
        /// 用户注册验证
        /// </summary>
        public const string REGISTERVALI = "/register/registerVali";

        /// <summary>
        /// 机构信息
        /// </summary>
        public const string ORGANSLIST = "/register/organs";


        /// <summary>
        /// 获取注册信息
        /// </summary>
        public const string REGISTERS = "/register/getReg";

        /// <summary>
        /// 机构信息
        /// </summary>
        public const string ORGANS = "/organ/organById";

        /// <summary>
        /// 车道信息
        /// </summary>
        public const string EXITINSPECTION = "/organ/exitInspection";


        /// <summary>
        /// 车道信息同步
        /// </summary>
        public const string EXITINSPECTIONSYNC = "/organ/syncExitInspection";


        /// <summary>
        /// 人员信息
        /// </summary>
        public const string PERSON = "/person/personByOrgan";


        /// <summary>
        /// 人员信息同步
        /// </summary>
        public const string PERSONSYNC = "/person/syncPerson";

        /// <summary>
        /// 用户信息
        /// </summary>
        public const string USER = "/user/userByOrgan";

        /// <summary>
        /// 用户信息同步
        /// </summary>
        public const string USERSYNC = "/user/syncUser";

        /// <summary>
        /// 企业信息
        /// </summary>
        public const string ENTERPRISE = "/organ/getEnterprises";


        /// <summary>
        /// 企业信息同步
        /// </summary>
        public const string ENTERPRISESYNC = "/organ/syncEnterprises";

        /// <summary>
        /// 车辆信息
        /// </summary>
        public const string CAR = "/car/getCars";

        /// <summary>
        /// 车辆信息同步标志
        /// </summary>
        public const string CARSYNC = "/car/syncCar";


        /// <summary>
        /// 票证信息
        /// </summary>
        public const string TICKET = "/ticket/ticketDetailed";

        /// <summary>
        /// 票证信息同步
        /// </summary>
        public const string TICKETSYNC = "/ticket/syncTicketDetailed";


        /// <summary>
        /// 附件上传
        /// </summary>
        public const string FILESYNC = "/file/uploadFile";

        /// <summary>
        /// JSON对象上传
        /// </summary>
        public const string JSONUPLOADBEAN = "/file/upLoadBean";


        /// <summary>
        /// 附件下载
        /// </summary>
        public const string JSONDOWNLOAD = "/file/downLoad";


        /// <summary>
        /// 验证数字
        /// </summary>
        public const string NUMBER_A = "^[0-9]*$";

        /// <summary>
        /// 验证n位的数字
        /// </summary>
        public const string NUMBER_B = @"^\d{n}$";

        /// <summary>
        /// 验证至少n位数字
        /// </summary>
        public const string NUMBER_C = @"^\d{n,}$";

        /// <summary>
        /// 验证m-n位的数字
        /// </summary>
        public const string NUMBER_D = @"^\d{m,n}$";

        /// <summary>
        /// 验证零和非零开头的数字
        /// </summary>
        public const string NUMBER_E = "^(0|[1-9][0-9]*)$";

        /// <summary>
        /// 验证有两位小数的正实数
        /// </summary>
        public const string NUMBER_F = "^[0-9]+(.[0-9]{2})?$";

        /// <summary>
        /// 验证有1-3位小数的正实数
        /// </summary>
        public const string NUMBER_G = "^[0-9]+(.[0-9]{1,3})?$";

        /// <summary>
        /// 验证非零的正整数
        /// </summary>
        public const string NUMBER_H = @"^\+?[1-9][0-9]*$";

        /// <summary>
        /// 验证非零的负整数
        /// </summary>
        public const string NUMBER_I = @"^\-[1-9][0-9]*$";

        /// <summary>
        /// 验证非负整数（正整数 + 0）
        /// </summary>
        public const string NUMBER_J = @"^\d+$";

        /// <summary>
        /// 验证非正整数（负整数 + 0）
        /// </summary>
        public const string NUMBER_K = @"^((-\d+)|(0+))$";
    }
}
